package com.by.mapper.purchase;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.by.entity.purchase.Enquiry;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;
import java.util.Map;

@Mapper
public interface EnquiryMapper extends BaseMapper<Enquiry> {
    /**
     * 查询待询价列表
     * @param map
     * @return
     */
    List<Map> queryWaitEnquriy(Map map);


    /**
     * 根据单据id查询未询价的产品
     * @param id 单据id
     * @return
     */
    Map queryEnquiryProduct(String id);

    /**
     * 保存询价单
     * @param enquiry
     * @return
     */
    int saveEnquiry(Enquiry enquiry);

    /**
     * 查询最大编码
     * @return
     */
    String queryMaxCode();
}
